#include "apue.h"
void main() {
	int c;
	while ((c = getc(stdin)) != EOF) {
		if (putc(c, stdout) == EOF)
			err_sys("putc error");
	}	
	if (ferror(stdin))
		err_sys("input error");
	return;
}
